package cn.ito.zjgsu.service;

import java.util.List;

import cn.ito.zjgsu.domain.Person;
import cn.ito.zjgsu.domain.Role;
import cn.ito.zjgsu.domain.UserLogin;
import cn.ito.zjgsu.domain.wrapper.PersonWrapper;
import cn.ito.zjgsu.domain.wrapper.RoleWrapper;

public interface RoleService {
	
	//删除角色
	public String deleteRole(int rid);
	public void deleteRoles(List<Integer> rids);
	
	//分页查询所有角色
	public List<Role> queryRoles(int pageNum , int records);
	
	//查询已关联某角色的员工集合
	public List<Person> queryPersonsLinkedRole(int roleId, int pageNum, int records, String key);
	public List<PersonWrapper> queryWrappedPersonsLinkedRole(int roleId, int pageNum, int records , String key);

	//查询角色未关联的员工集合
	public List<PersonWrapper> queryRoleUnrelatedWrappedPerson(int roleId, int pageNum, int records);
	public List<Person> queryRoleUnrelatedPerson(int roleId, int pageNum, int records);

	//通过角色id查询角色
	public RoleWrapper queryRoleWrapperByRid(int roleId);

	
	//更新角色权限关系
	public String updateRoleWrapper(RoleWrapper rw);

	//创建可带权限关联的role
	public String createRole(RoleWrapper rw);
	
	//查询角色已关联/未关联员工
	public String queryUsersLinkedRole(int roleId ,int pageNum, int records);
	public String queryUsersDislinkedRole(int roleId ,int pageNum, int records, String key);
	public List<UserLogin> queryUsersObLinkedRole(int roleId, int pageNum, int records);
	public List<UserLogin> queryUsersObDislinkedRole(int roleId, int pageNum, int records);
	public List<Person> queryPersonsDislinkedRole(int i, int pageNum, int records, String key);

	 
	
}
